package com.smartwork.common.mobile.wechat.constant;

public class StaticValue {

	public final static String getTokenUrl = "https://api.weixin.qq.com/cgi-bin/token?grant_type=client_credential&appid=%s&secret=%s";

    /** 生成二维码 */
    public final static String qrcodeTicketUrl = "https://api.weixin.qq.com/cgi-bin/qrcode/create?access_token=%s";
    public final static String showQrcodeUrl = "https://mp.weixin.qq.com/cgi-bin/showqrcode?ticket=%s";
    /** 授权并获取用户信息 */
    public final static String oAuthCodeUrl = "https://open.weixin.qq.com/connect/oauth2/authorize?appid=%s&redirect_uri=%s&response_type=code&scope=snsapi_userinfo&state=%s#wechat_redirect";
    public final static String oAuthSimpleCodeUrl = "https://open.weixin.qq.com/connect/oauth2/authorize?appid=%s&redirect_uri=%s&response_type=code&scope=snsapi_base&state=%s#wechat_redirect";
    public final static String oAuthTokenUrl = "https://api.weixin.qq.com/sns/oauth2/access_token?appid=%s&secret=%s&code=%s&grant_type=authorization_code";
    public final static String oAuthRefreshTokenUrl = "https://api.weixin.qq.com/sns/oauth2/refresh_token?appid=%s&grant_type=refresh_token&refresh_token=%s";
    public final static String oAuthFetchUserMsgUrl = "https://api.weixin.qq.com/sns/userinfo?access_token=%s&openid=%s&lang=zh_CN";
    /** 公众号菜单 */
    public final static String menuFetchUrl = "https://api.weixin.qq.com/cgi-bin/menu/get?access_token=%s";
    public final static String menuCreateUrl = "https://api.weixin.qq.com/cgi-bin/menu/create?access_token=%s";
    /** 微信素材 */
    public final static String mediaListUrl = "https://api.weixin.qq.com/cgi-bin/material/batchget_material?access_token=%s";
    public final static String uploadNewsUrl = "https://api.weixin.qq.com/cgi-bin/media/uploadnews?access_token=%s";
    public final static String uploadMediaUrl = "http://api.weixin.qq.com/cgi-bin/material/add_material?access_token=%s";
    public final static String uploadTempMediaUrl = "https://api.weixin.qq.com/cgi-bin/media/upload?access_token=%s&type=%s";
    /** jsApiTicket 获取 */
    public final static String jsApiTicketFetch = "https://api.weixin.qq.com/cgi-bin/ticket/getticket?type=1&access_token=%s";

    /** 用户管理 */
    public final static String userGroupFetch = "https://api.weixin.qq.com/cgi-bin/groups/get?access_token=%s";

    /** 群发消息 */
    public final static String massMsgUrl = "https://api.weixin.qq.com/cgi-bin/message/mass/sendall?access_token=%s";
    
    public final static String massTmplMsgUrl = "https://api.weixin.qq.com/cgi-bin/message/template/send?access_token=%s";
    
    /** String.format 相关 */
    public final static String formatTempQrcodeTicketJson = "{\"expire_seconds\": 1800, \"action_name\": \"QR_SCENE\", \"action_info\": {\"scene\": {\"scene_id\": %d}}}";
    public final static String formatQrcodeTicketJson_int = "{\"action_name\": \"QR_LIMIT_SCENE\", \"action_info\": {\"scene\": {\"scene_id\": %d}}}";
    public final static String formatQrcodeTicketJson_str = "{\"action_name\": \"QR_LIMIT_STR_SCENE\", \"action_info\": {\"scene\": {\"scene_str\": \"%s\"}}}";
    public final static String formatMassNewsToAll = "{\"filter\":{\"is_to_all\":true},\"mpnews\":{\"media_id\":\"%s\"},\"msgtype\":\"mpnews\"}";

    /** 支付相关 */
    public static final String unifiedorderUrl = "https://api.mch.weixin.qq.com/pay/unifiedorder";
    public static final String orderQueryUrl = "https://api.mch.weixin.qq.com/pay/orderquery";
    public static final String orderClostUrl = "https://api.mch.weixin.qq.com/pay/closeorder";
    public static final String refundUrl = "https://api.mch.weixin.qq.com/secapi/pay/refund";
    public static final String refundQueryUrl = "https://api.mch.weixin.qq.com/pay/refundquery";
    public static final String downloadbillUrl = "https://api.mch.weixin.qq.com/pay/downloadbill";
    public static final String reportUrl = "https://api.mch.weixin.qq.com/payitil/report";
    public static final String shortUrl = "https://api.mch.weixin.qq.com/tools/shorturl";

//    public static String getAppId() {
//        return WeixinProperties.getStrValue("appID");
//    }
//
//    public static String getAppSecret() {
//        return WeixinProperties.getStrValue("appsecret");
//    }

}
